﻿Imports System.Runtime.CompilerServices
<Extension()> _
Module ExtensionMethods

    <Extension()> _
    Public Function AppendFolder(ByVal url As Uri, ByVal value As String) As Uri
        If String.IsNullOrEmpty(value) Then
            Return url
        End If

        Return New Uri(String.Format("{0}/{1}/", url.ToString().TrimEnd(" /".ToCharArray()), value.TrimEnd(" /".ToCharArray())))
    End Function

End Module
